package megrez.common.util;

import java.util.Arrays;

import lombok.experimental.UtilityClass;

/**
 * 数组工具
 *  
 * @author Lucky Yang
 * @since 0.0.1
 */
@UtilityClass
public class ArrayHelper {
    public <T> T[] concatWithStream(T[] array1, T[] array2, Class<T> clazz) {
        T[] result = Arrays.copyOf(array1, array1.length + array2.length);
        System.arraycopy(array2, 0, result, array1.length, array2.length);
        return result;
    }
}
